home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / clipper / hlpsy203.zip / MAKETEST.PRG < prev    next >
Text File  |  1994-03-10  |  1KB  |  35 lines

  1. * For normal .DBF and .NTX testing, leave both comment sections below
  2. * commented
  3. *
  4. #define TOTAL_RECORDS 100
  5.  
  6. FIELD Field1, Field2, Field3 IN Test
  7. LOCAL nCount
  8. * * * * FOR COMIX * * * * * * * *
  9. *  REQUEST DBFCMX             // Force a link to FlexFile
  10. *  RDDSETDEFAULT("DBFCMX")    // Set the Default RDD to Comix
  11. * * * * FOR FLEXFILE* * * * * * *
  12. *  REQUEST FLEXFILE           // Force a link to FlexFile
  13. *  RDDSETDEFAULT("FLEXFILE")  // Set the Default RDD to FlexFile
  14. * * * * * * * * * * * * * * * * *
  15. *  V_SUPERRDD("DBFCMX")       // Set COMIX on top of FlexFile
  16. * * * * * * * * * * * * * * * * *
  17.  
  18. * Create a Test database
  19. DBCREATE("TEST", {{"Field1","C",10,0},{"Field2","C",10,0},;
  20.                   {"Field3","C",10,0},{"Field4","C",10,0}},)
  21.  
  22. USE Test                             // Open Database in Single User Mode
  23. INDEX ON UPPER(Field1) TO Test1      // Create Index 1
  24. INDEX ON UPPER(Field2) TO Test2      // Create Index 2
  25. INDEX ON UPPER(Field3) TO Test3      // Create Index 3
  26. USE Test INDEX Test1,Test2,Test3     // Open Database and indexes
  27. FOR nCount := 1 TO TOTAL_RECORDS     // Loop for creating records
  28.     APPEND BLANK                     // Add a blank record
  29.     Field1 := STR(nCount)            // Make dummy field assignments
  30.     Field2 := "Field2"
  31.     Field3 := "Field3"
  32. NEXT nCount                          // End of Loop
  33. USE                                  // Close Database and End
  34.                                   
  35.